package ro.gui;

import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;
import javax.swing.ImageIcon;
import javax.swing.JDesktopPane;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextPane;
import javax.swing.JTextField;

import ro.io.Texture;

public class GUI extends JFrame {

	final JDesktopPane desktopPane;
	public JPanel panel;
	public BufferedImage picture;	
	public JLabel picLabel;
	
	public GUI() throws IOException {
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setTitle("Rozpoznawanie Obraz\u00F3w");
		setBounds(0, 0, 820, 820);
		desktopPane = new JDesktopPane();
		desktopPane.setBackground(Color.GRAY);
		getContentPane().add(desktopPane, BorderLayout.CENTER);

		panel = new JPanel();
		panel.setBounds(0, 0, 800, 800);
		desktopPane.add(panel);
		//panel.setLayout(null);

		textField = new JTextField();
		textField.setBounds(364, 171, 132, 47);
		panel.add(textField);
		textField.setColumns(10);
		
		//Texture t = new Texture(new File("C:\\texture-train\\straw\\straw001.bmp"));
		
		//picture = ImageIO.read(new File("C:\\texture-train\\straw\\straw001.bmp"));
		//picLabel = new JLabel(new ImageIcon(t.img));
		
		//JLabel picLabel2 = new JLabel(new ImageIcon(picture));
		//panel.add(picLabel2);
		//panel.add(picLabel);
	}

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private JTextField textField;
}
